//
//  UITextField+Additional.m
//  DoubanProject
//
//  Created by 花磊 on 15/5/13.
//  Copyright (c) 2015年 lanou3g. All rights reserved.
//

#import "UITextField+Additional.h"

@implementation UITextField (Additional)

- (instancetype)initWithFrame:(CGRect)frame placeholder:(NSString *)placeholder security:(BOOL)security borderStyle:(UITextBorderStyle)borderStyle {
    
    return [self initWithFrame:frame placeholder:placeholder security:security borderStyle:borderStyle keyboardType:UIKeyboardTypeDefault];
}

- (instancetype)initWithFrame:(CGRect)frame placeholder:(NSString *)placeholder security:(BOOL)security borderStyle:(UITextBorderStyle)borderStyle keyboardType:(UIKeyboardType)keyboardType {
    
#warning 如果是在本类中的初始化方法，使用super。如果是在类目中，使用self。
    self = [self initWithFrame:frame];
    if (self) {
        self.placeholder = placeholder;
        self.secureTextEntry = security;
        self.borderStyle = borderStyle;
        self.keyboardType = keyboardType;
    }
    return self;
}

@end
